Skip to content

fix(recon-wasm): restore missing builtins.rs (E0583 build blocker)#40

Merged
hyperpolymath merged 1 commit into
mainfrom
fix/recon-wasm-missing-builtins
May 16, 2026
Merged

fix(recon-wasm): restore missing builtins.rs (E0583 build blocker)#40
hyperpolymath merged 1 commit into
mainfrom
fix/recon-wasm-missing-builtins

Conversation

@hyperpolymath

Copy link
Copy Markdown
Owner

Problem

reconforth/mod.rs declared mod builtins; and pub use builtins::register_builtins, and vm.rs calls register_builtins(&mut vm) from VM::new(), but builtins.rs was never committed. The recon-wasm crate did not compile (E0583: file not found for module builtins``). This also blocked verifying the crypto work in PR #39.

Fix

Restores the core ReconForth native vocabulary the VM + existing tests rely on:

  • arithmetic + - * / mod neg
  • comparison = != < > <= >=
  • boolean and or not true false
  • stack dup drop swap over rot nip depth
  • control call if ifelse
  • validation error! warn! suggest! (symmetric with VM::report_*)
  • doc-reconciliation count doc-type is-canonical

All words total/fallible — no unwrap/panic! (estate robustness policy).

Verification

  • cargo build: clean (only pre-existing unrelated warnings)
  • cargo test --lib: 32/32 pass, including the previously-failing tests::test_reconforth_validation

Unblocks build-verification of PR #39 (crypto).

🤖 Generated with Claude Code

reconforth/mod.rs declared `mod builtins;` / `pub use
builtins::register_builtins`, and vm.rs calls `register_builtins(&mut vm)`
from `VM::new()`, but `builtins.rs` was never committed — the recon-wasm
crate failed to compile (E0583), which also blocked verifying the crypto
work in PR #39.

Restores the core ReconForth native vocabulary the VM and its existing
tests depend on: arithmetic (+ - * / mod neg), comparison (= != < > <= >=),
boolean (and or not true false), stack (dup drop swap over rot nip depth),
control (call if ifelse), validation reporting (error! warn! suggest!),
and document-reconciliation helpers (count doc-type is-canonical).

All words are total and fallible — no unwrap/panic, per estate robustness
policy. cargo build clean; cargo test --lib: 32/32 pass (incl. the
previously-failing tests::test_reconforth_validation).

Co-Authored-By: Claude Opus 4.7 <noreply@anthropic.com>
@hyperpolymath hyperpolymath merged commit fc73346 into main May 16, 2026
19 of 21 checks passed
@hyperpolymath hyperpolymath deleted the fix/recon-wasm-missing-builtins branch May 16, 2026 14:53
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant